-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow to use ansible-test's change detection for Pull Requests #49
Allow to use ansible-test's change detection for Pull Requests #49
Conversation
It's because the AZP scripts don't do this either, so I don't see why I want to have some of the CI runs to send coverage data and the others (which will be the majority) none.
That's what I'm planning to implement anyway. I want to be able to turn off code coverage reporting completely. (Not being able to do so prevented me using this action in a role only collection, as with stable-2.9 the action errors out if there are no coverage reports to upload.) |
Failing CI is unrelated... |
Looks like this wouldn't apply to the repos that don't use AZP at all. Note that among this action, users are projects outside the @ansible-collections community. I'd very much want them to be able to take advantage of the practices that are common among more generic software projects on GitHub, not limiting them with what the Ansible Community does currently. |
What exactly fails? Can this be fixed in the action? |
See https://github.com/felixfontein/ansible-acme/actions/runs/3315379162/jobs/5475899754 |
As I said, I don't mind making code coverage configurable in the sense that you can say "always enable", "always disable", or "only enable when no change detection is used" (i.e. as in this PR). I still don't think that these carryforward flags will work and I don't want to implement that though. And also I don't think this extra configurability should happen in this PR. |
This patch introduces a `pull-request-change-detection` action input that allows the end-users to request running `ansible-test` in change detection mode. It is only supported in for pull requests at the moment because `ansible-test` does not currently know how to interact with the environment variables that GitHub Actions CI/CD workflows set [1]. With this feature, the users will be able to save some of the CI compute time due to `ansible-test` skipping the tests that are not affected by the changes in PRs. [1] https://github.com/ansible-community/ansible-test-gh-action/pull/49/files#r1023412786
97de31d
to
5257e71
Compare
@felixfontein thanks for the patch! I've cleaned it up a bit and released as v1.12.0. Have fun with it! |
@webknjaz thanks for reviewing, cleaning up, and merging! |
Re-opening #46. I rebased with latest
main
and squashed some commits.